package br.com.musclebook.entity;

import java.io.Serializable;

import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import br.com.musclebook.enums.ExerciseCategory;

@Entity
@Table(name = "EXERCISE_SECUNDARY_CATEGORIES")
public class ExerciseSecondaryCategory implements Serializable {

    private static final long serialVersionUID = 1L;

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @ManyToOne
    @JoinColumn(name = "EXERCISE_ID")
    private Exercise exercise;

    @Enumerated(EnumType.ORDINAL)
    private ExerciseCategory category;

    public Long getId() {
	return id;
    }

    public void setId(Long id) {
	this.id = id;
    }

    public Exercise getExercise() {
	return exercise;
    }

    public void setExercise(Exercise exercise) {
	this.exercise = exercise;
    }

    public ExerciseCategory getCategory() {
	return category;
    }

    public void setCategory(ExerciseCategory category) {
	this.category = category;
    }

}
